package org.subject.service;

import org.apache.ibatis.annotations.Param;
import org.subject.dto.RegisteMessage;
import org.subject.dto.RegisteUserMessage;
import org.subject.entity.Registration;
import org.subject.entity.User;

import java.util.List;

/**
 * Created by kai on 2017/5/6.
 */
public interface RegistrationService {

    List<User> selectUserList(String messageId);

    int insert(@Param("messageId") String messageId, @Param("userId") String userId);

    Registration selectByMIdUid(@Param("messageId") String messageId, @Param("userId") String userId);

    List<RegisteMessage> selectRegisteMessage(String messageId);

    List<RegisteUserMessage> selectRegisteUserMessage(String userId);

    Registration selectByPrimaryKey(String registrationId);

    int updateByPrimaryKey(Registration registration);

    /**
     * 根据竞赛信息id和院系id查询报名列表
     *
     * @param messageId
     * @param facultyId
     * @return
     */
    List<User> selectUserListByFId(@Param("messageId") String messageId, @Param("facultyId") String facultyId);
}
